<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
	<head>
		<title>选择主题词</title>
		<link href="css/table.css" rel="stylesheet" type="text/css" />
		<script type="text/javascript" src="js/jquery-1.4.2.min.js"></script>
		<script type="text/javascript">
		function subjectAddout(){
			var a =$("input[name='subject']");
			var c ="";
			var count=0;
			for(var i=0;i<a.length;i++){
				if(a[i].checked){
				c +=a[i].value+"  ";
				count++;
				}
			}
			if(count==0){
				alert("请选择主题词！");
				return;
			}
			if( c != null){
				opener.subjectAddouts(c);
				window.close();
			}
		}
	</script>
	</head>
	<body>
	<table align="center" border="0" cellpadding="0" cellspacing="0" width="100%">
			<tbody>
				<tr>
					<td style="background: url('image/wsoa_window_002.gif');" width="1"></td>
					<td style="background: url('image/wsoa_window_002.gif');">
						<table border="0" cellpadding="0" cellspacing="0">
							<tbody>
								<tr>
									<td align="center"
										style="background: url('image/wsoa_window_002.gif');"
										width="10">
										<img src="image/center_19.gif">
									</td>
									<td align="center"
										style="background: url('image/wsoa_window_002.gif');"></td>
									<td>
										选择主题词
									</td>
								</tr>
							</tbody>
						</table>
					</td>
					<td style="background: url('image/wsoa_window_002.gif');" width="1"></td>
				</tr>
				<tr>
					<td style="background: url('image/wsoa_window_010.gif');" width="1">
						&nbsp;
					</td>
					<td>
		<table width="100%" align="center">
					<c:forEach items="${subjectList}" var="subject">
			<tr>
						<td style="border-bottom: 1px #ccc double;">
								<input type="checkbox" name="subject" title="${subject.content }" id="subject" value="${subject.content }">${subject.content }<br>
						</td>
			</tr>
					</c:forEach>
					<tr>
						<td align="center">
					<input class="button_02" type="button" onclick="subjectAddout()" value="添加">
						</td>
					</tr>
		</table>
		
		</td>
					<td style="background: url('image/wsoa_window_006.gif');" width="1">
						&nbsp;
					</td>
				</tr>
				<tr>
					<td height="1" width="1">
						<img src="image/wsoa_window_009.gif" height="16" width="14">
					</td>
					<td style="background: url('image/wsoa_window_008.gif');"
						height="1"></td>
					<td height="1" width="1">
						<img src="image/wsoa_window_007.gif" height="16" width="12">
					</td>
				</tr>
			</tbody>
		</table>
	</body>
</html>
